import { Spin } from "antd";
import React from "react";
import {Routes,Route,HashRouter} from "react-router-dom";

const Login = React.lazy(() => import("./view/login/login"));
const LayoutComment=React.lazy(()=>import("./layout/layout"));

export default function RouterComponent() {
    return (
        <React.Suspense fallback={<Spin />}>
            <HashRouter>
                <Routes>
                    <Route path="/login"  element={<Login/>} />
                    <Route path="/layout" element={<LayoutComment/>} />
                </Routes>
            </HashRouter>
        </React.Suspense>
    );
}